package com.HRs.domain;

import com.HRs.Controller.PatientController;

import java.text.SimpleDateFormat;
import java.util.Date;

public class Patient {
    private String p_Pid;
    private String p_Name;
    private String p_Password;
    private String p_Sex;
    private String p_Address;
    private String p_ID;
    private String P_PhoneNumber;
    private static Integer id = 1000;

    {
        id += 1 ;
    }

    public Patient(){}

    public Patient(String p_Name, String p_Password, String p_Sex, String p_Address, String p_ID, String p_PhoneNumber) {
        PatientController pc = new PatientController();
        this.p_Pid = pc.get_Pid();
        this.p_Name = p_Name;
        this.p_Password = p_Password;
        this.p_Sex = p_Sex;
        this.p_Address = p_Address;
        this.p_ID = p_ID;
        this.P_PhoneNumber = p_PhoneNumber;
    }

    public Patient(String p_Pid, String p_Name, String p_Password, String p_Sex, String p_PhoneNumber, String p_Address, String p_ID) {
        this.p_Pid = p_Pid;
        this.p_Name = p_Name;
        this.p_Password = p_Password;
        this.p_Sex = p_Sex;
        this.p_Address = p_Address;
        this.p_ID = p_ID;
        this.P_PhoneNumber = p_PhoneNumber;
    }

    @Override
    public String toString() {
        return "Patient{" +
                "p_Pid='" + p_Pid + '\'' +
                ", p_Name='" + p_Name + '\'' +
                ", p_Password='" + p_Password + '\'' +
                ", p_Sex='" + p_Sex + '\'' +
                ", p_Address='" + p_Address + '\'' +
                ", p_ID='" + p_ID + '\'' +
                ", P_PhoneNumber='" + P_PhoneNumber + '\'' +
                '}';
    }

    public String getP_Pid() {
        return p_Pid;
    }

    public void setP_Pid(String p_Pid) {
        this.p_Pid = p_Pid;
    }

    public String getP_Name() {
        return p_Name;
    }

    public void setP_Name(String p_Name) {
        this.p_Name = p_Name;
    }

    public String getP_Password() {
        return p_Password;
    }

    public void setP_Password(String p_Password) {
        this.p_Password = p_Password;
    }

    public String getP_Sex() {
        return p_Sex;
    }

    public void setP_Sex(String p_Sex) {
        this.p_Sex = p_Sex;
    }

    public String getP_Address() {
        return p_Address;
    }

    public void setP_Address(String p_Address) {
        this.p_Address = p_Address;
    }

    public String getP_ID() {
        return p_ID;
    }

    public void setP_ID(String p_ID) {
        this.p_ID = p_ID;
    }

    public String getP_PhoneNumber() {
        return P_PhoneNumber;
    }

    public void setP_PhoneNumber(String p_PhoneNumber) {
        P_PhoneNumber = p_PhoneNumber;
    }

}
